home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_02_06
/
2n06020b
< prev
next >
Wrap
Text File
|
1991-04-28
|
465b
|
17 lines
#include <stdio.h>
#include <string.h>
#include "snooper.h"
FILE *open_stream(const char *fname, const char *mode )
{
FILE *fp;
__WATCH(!fname || !(*fname),__SCRN__,
d_printf("open_stream(): "
"null pointer or -> null filename\n" ));
fp = fopen(fname,mode);
__WATCH(fp == NULL, __SCRN__,
d_printf("open_stream(): "
"can't open file %s\n", fname ));
return fp;
}